import request from '@/utils/request'
import { qss } from '../utils/request'

export function list(query) {
  return request({
    url: '/sys/menu/list',
    method: 'get',
    params: query
  })
}

export function info(id) {
  return request({
    url: '/sys/menu/info/' + id,
    method: 'get'
  })
}

export function save(data) {
  data = qss(data)
  return request({
    url: '/sys/menu/save',
    method: 'post',
    data
  })
}

export function update(data) {
  data = qss(data)
  return request({
    url: '/sys/menu/update',
    method: 'post',
    data
  })
}

export function remove(ids) {
  const data = ids
  return request({
    url: '/sys/menu/delete',
    method: 'post',
    data
  })
}

